<?php 

class ValidatedFile extends sfValidatedFile
{

	public function generateFilename()
	{
		if($this->savedName === null)
			return parent::generateFilename();
		else
			return $this->savedName . $this->getOriginalExtension();
	}

	public function setSavedName($name)
	{
		$this->savedName = $name;
	}

}